<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<base href="<?php echo base_url();?>"/>
		<link href="css/comm.css" rel="stylesheet" type="text/css" />
		<script src="js/comm.js"></script>
	</head>
	<body>
		<dl>
			<dt><?=$forum['forum_name']?></dt>
			<dd>
				<?
					if(isset($forum['desc']))echo($forum['desc']);
				?>
			</dd>
			<dd>
				<?
					if(isset($forum['nickname']))echo('版主:<a href="'.site_url('member/user_info/'.$forum['user_id']).'">'.$forum['nickname']."</a>");
				?>
			</dd>
			<dd>
				<a href="<?=site_url('message/insert/'.$forum['id'])?>">发表新文章</a>
			</dd>
		</dl>
		<?php
			if(count($messages['row'])>0){
		?>
		<table>
			<tr>
				<td>类型</td>
				<td>主题</td>
				<td>作者</td>
				<td>时间</td>
			</tr>
			<?php
				foreach($messages['row'] as $value){
			?>
			<tr>
				<td>
				<?php
					if($value['top_lv']>0)echo('[置顶] ');
					if($value['marrow_lv']>0)echo('[精华] ');
				?>
				</td>
				<td><?='<a href="'.site_url('message/'.$value['id']).'">'.$value['title'].'</a></li>'?></td>
				<td><?='<a href="'.site_url('member/user_info/'.$value['user_id']).'">'.$value['nickname'].'</a>'?></td>
				<td><?=date('Y-m-d',strtotime($value['create_time']))?></td>
			</tr>
			<?
				}
			?>
		</table>
		<div><?=$pager?></div>
		<?php
			}
			else{
				echo('<h1>no record...!</h1>');
			}
		?>
		
	</body>
</html>